package com.wgts.wgts.dagger.module;

import com.wgts.wgts.dagger.scope.ActivityScope;
import com.wgts.wgts.mvp.model.IWgtsResetPasswordActivityModel;
import com.wgts.wgts.mvp.model.imp.WgtsResetPasswordActivityModel;
import com.wgts.wgts.mvp.presenter.IWgtsResetPasswordActivityPresenter;
import com.wgts.wgts.mvp.presenter.imp.WgtsResetPasswordActivityPresenter;
import com.wgts.wgts.mvp.view.IWgtsResetPasswordActivityView;
import com.wgts.wgts.netmodle.NetService;

import dagger.Module;
import dagger.Provides;

/*
 *   author:handsome
 *   data:2018/11/717:36
 *   packeage:${PAKAGE_NAME}
 *
 */
@Module
public class WgtsResetPasswordActivityModule {
    private IWgtsResetPasswordActivityView view;

    public WgtsResetPasswordActivityModule(IWgtsResetPasswordActivityView view) {
        this.view = view;
    }

    @ActivityScope
    @Provides
    public IWgtsResetPasswordActivityView provideView(){
        return view;
    }

    @ActivityScope
    @Provides
    public IWgtsResetPasswordActivityModel provideModel(NetService netService){
        return new WgtsResetPasswordActivityModel(netService);
    }

    @ActivityScope
    @Provides
    public IWgtsResetPasswordActivityPresenter providePresenter(IWgtsResetPasswordActivityView view, IWgtsResetPasswordActivityModel model){
        return new WgtsResetPasswordActivityPresenter(view, model);
    }
}
